import http from '@/utils/axios';

// 获取版本列表
export const getWithdrawalApplyList = (params: any) => {
    return http({
        method: 'get',
        url: '/withdrawal_apply/index',
        params,
    });
};

// 获取版本详情信息
export const getWithdrawalApplyInfo = (userId: number) => {
    return http({
        method: 'GET',
        url: `/withdrawal_apply/read/${userId}`,
    });
};

// 新增版本信息
export const saveWithdrawalApplyInfo = (data: any) => {
    return http({
        method: 'POST',
        url: `/withdrawal_apply/save`,
        data,
    });
};

// 更新版本信息
export const updateWithdrawalApplyInfo = (userId: number, data: any) => {
    return http({
        method: 'PUT',
        url: `/withdrawal_apply/update/${userId}`,
        data,
    });
};

// 删除版本
export const deleteWithdrawalApply = (userId: number) => {
    return http({
        method: 'DELETE',
        url: `/withdrawal_apply/delete/${userId}`,
    });
};